/**
 * 
 */
package com.joinfun.rdsdk.mingdao.utils;

import org.apache.commons.configuration.Configuration;
import org.apache.commons.configuration.ConfigurationException;
import org.apache.commons.configuration.PropertiesConfiguration;

/**
 * @author FMK
 * 2014年1月5日下午12:37:40
 *
 */
public class ConfigurationManager {
	private static Configuration config;
	
	public static String get(String key) {
		return getConfig().getString(key);
	}
	
	public static Configuration getConfig(){
		if(config == null) {
			try {
				config = new PropertiesConfiguration("config.properties");
			} catch (ConfigurationException e) {
				e.printStackTrace();
			}
		}
		return config;
	}
	
}
